<template>
  <div class="container">
    <div class="wrapper" v-html="this.Agreement.content" ></div>
  </div>
</template>

<script>
import { getPackageAgreement } from '@/api/market'
export default {
  name: 'userAgreement',
  data () {
    return {
      Agreement: {
        content: '',
        title: ''
      }
    }
  },
  mounted () {
    this.getPackageAgreementAjax()
  },
  methods: {
    // 获取该用户名下所有的油站
    async getPackageAgreementAjax () {
      try {
        const { result } = await getPackageAgreement()
        // if ()
        this.Agreement = result || []
        this.Agreement.content = decodeURIComponent(this.Agreement.content)
      } catch (err) {
        console.log(err)
      }
    },
  }
}
</script>

<style lang="less" scoped>
.container {
  background: #ffffff;
  padding: 30px;
  font-size: 14px;
  color: #333333;
  line-height: 24px;
}
.wrapper{
  white-space: pre-wrap;
}
</style>
